<template>
  <div id="app">
    <keep-alive include="UserHomePage">
      <router-view></router-view>
    </keep-alive>

  </div>
</template>
<script>
export default {
  name: 'App',
  methods: {
    _isMobile() {
      let flag = navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i)
      return flag;
    }
  },
  mounted() {
    if (this._isMobile()) {
      window.document.title="StarLight-Movie"
      this.$router.replace('/mobile')
    }
  }
}
</script>

<style>
body{
  padding: 0;
  margin: 0 !important;
}
</style>
